@echo off
rem
rem /*
rem +-----------------------------------------------------------------------------+
rem | $Id: __import_mysql.bat,v 1.0 2009/08/26 08:08:28Z Bleakwind $
rem | Import Mysql For Win
rem | Copyright (c) 2003-2010 Bleakwind (www.weaverdream.com)
rem | http://www.weaverdream.com/
rem | Release under the GNU Lesser General Public License Version 3 (LGPLv3):
rem |   http://www.gnu.org/licenses/lgpl.html
rem +-----------------------------------------------------------------------------+
rem */
rem

set sql_username=bleakwind
set sql_password=bleakwind
set sql_database=project_...
set sql_filename=mysql.sql

title Import SQL...
color 0A

@echo ##############################
@echo #    www.weaverdream.com     #
@echo #      Please wait ...       #
@echo ##############################

SET /P if_import="Import SQL to %sql_database%? [y/n]:"
if "%if_import%"=="y" (goto :IF_IMPORT_YES) else (goto :IF_IMPORT_NOT)

:IF_IMPORT_YES
@echo Start to import SQL...
"D:\SnowServer\MySQL Server 5.0\bin\mysql" -u%sql_username% -p%sql_password% --default-character-set=utf8 %sql_database% < .\install\%sql_filename%
@echo Import SQL successful...
GOTO END

:IF_IMPORT_NOT
@echo SQL not import...
GOTO END

:END
pause
